#pragma once
#include <boost\thread\mutex.hpp>
#include <boost\thread\condition_variable.hpp>
#include "../EventManager/interfaces.h"
#include <queue>
namespace re{
	namespace real{

template <class T>
class ThreadSafeQueue
{
public:
	ThreadSafeQueue() {}
	~ThreadSafeQueue() {}
	
	void push(T& data);
	bool wait_pop(T& data);
	bool try_pop(T& data);
	bool is_empty();

private:
	std::queue<IEventData> m_queue;
	mutable boost::mutex m_mutex;
	boost::condition_variable m_condition_var;
};


}
}